package com.wg.msshopsp.controller;

import com.wg.msshopsp.entity.ReviewShop;

import com.wg.msshopsp.service.ReviewShopService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/shop")
public class ReviewShopController {
    @Autowired
    private ReviewShopService reviewShopService;
    @PostMapping("/reviewShop")
    public int insertReviewShop(@RequestBody ReviewShop reviewShop)
        {
            return reviewShopService.save(reviewShop)? 1 : 0;
        }
}
